<template>
   <van-search
      autofocus
      show-action
      shape="round"
      v-model="value"
      placeholder="请输入搜索关键词"
      @search="onSearch"
    >
    </van-search>
</template>

<script>
export default {
    data() {
    return {
      value: "", //用于双向绑定到输入框
    };
  },
  methods:{
    onSearch(){
        
            this.$router.push('/searchResult/' + this.value)
        
    }
  }
}
</script>

<style>

</style>